package cn.yh.shop.user.model;


import java.sql.Timestamp;
import java.util.ArrayList;
import java.util.List;


/**
 * @Description:订单实体类
 * @author:"李战召"
 * @time:2016年12月22日 上午9:51:52
 */
public class UserOrder implements java.io.Serializable {


	/**
	 * @Description: serialVersionUID : 序列话版本号
	 */
	private static final long serialVersionUID = 1L;
	/**
	 * @Description: id : 订单id订单编号 Redis生成一个有规律的,当redis出现异常是,随机产生uuid
	 */
	private String id;
	/**
	 * @Description: beginTime : 订单开始时间;提交订单时生成
	 */
	private Timestamp beginTime;
	/**
	 * @Description: endTime : 订单成交时间;用户付款后生成
	 */
	private Timestamp endTime;
	/**
	 * @Description: status : 订单状态;1:未付款(默认) 2:已付款未发货 3:未收货 4:未评价 5:已评价
	 */
	private Integer status;
	/**
	 * @Description: userId : 用户id
	 */
	private Integer userId;
	/**
	 * @Description: logisticsId : 物流编号 ;发货后添加
	 */
	private String logisticsId;
	/**
	 * @Description: isAvailable : 订单是否有效;1:订单有效(默认) 2:订单失效
	 */
	private Integer isAvailable;
	/**
	 * @Description: totalPrice : 订单总价
	 */
	private Double totalPrice;
	/**
	 * @Description: expressFee : 邮费
	 */
	private Double expressFee;
	/**
	 * @Description: altPeopleName : 最后一次修改订单的人
	 */
	private String altPeopleName;
	/**
	 * @Description: altTime : 最后一次修改的时间
	 */
	private Timestamp altTime;
	/**
	 * @Description: isReceive : 判断交易是否成功1:交易成功2:交易失败(成功销量加1)
	 */
	private Integer isReceive;
	/**
	 * @Description: orderItems : 订单项的items集合
	 */
	private List<UserOrderItem> orderItems = new ArrayList<UserOrderItem>();
	
	public Integer getIsReceive() {
		return isReceive;
	}

	public void setIsReceive(Integer isReceive) {
		this.isReceive = isReceive;
	}

	/** default constructor */
	public UserOrder() {
	}


	public String getId() {
		return this.id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public Timestamp getBeginTime() {
		return this.beginTime;
	}

	public void setBeginTime(Timestamp beginTime) {
		this.beginTime = beginTime;
	}

	public Timestamp getEndTime() {
		return this.endTime;
	}

	public void setEndTime(Timestamp endTime) {
		this.endTime = endTime;
	}

	public Integer getStatus() {
		return status;
	}

	public void setStatus(Integer status) {
		this.status = status;
	}

	public Integer getUserId() {
		return this.userId;
	}

	public void setUserId(Integer userId) {
		this.userId = userId;
	}

	public String getLogisticsId() {
		return this.logisticsId;
	}

	public void setLogisticsId(String logisticsId) {
		this.logisticsId = logisticsId;
	}

	public Integer getIsAvailable() {
		return this.isAvailable;
	}

	public void setIsAvailable(Integer isAvailable) {
		this.isAvailable = isAvailable;
	}

	public Double getTotalPrice() {
		return this.totalPrice;
	}

	public void setTotalPrice(Double totalPrice) {
		this.totalPrice = totalPrice;
	}

	public Double getExpressFee() {
		return this.expressFee;
	}

	public void setExpressFee(Double expressFee) {
		this.expressFee = expressFee;
	}

	public String getAltPeopleName() {
		return this.altPeopleName;
	}

	public void setAltPeopleName(String altPeopleName) {
		this.altPeopleName = altPeopleName;
	}

	public Timestamp getAltTime() {
		return this.altTime;
	}

	public void setAltTime(Timestamp altTime) {
		this.altTime = altTime;
	}

	public List<UserOrderItem> getOrderItems() {
		return orderItems;
	}

	public void setOrderItems(List<UserOrderItem> orderItems) {
		this.orderItems = orderItems;
	}

	@Override
	public String toString() {
		return "UserOrder [id=" + id + ", beginTime=" + beginTime + ", endTime=" + endTime + ", status=" + status
				+ ", userId=" + userId + ", logisticsId=" + logisticsId + ", isAvailable=" + isAvailable
				+ ", totalPrice=" + totalPrice + ", expressFee=" + expressFee + ", altPeopleName=" + altPeopleName
				+ ", altTime=" + altTime + ", isReceive=" + isReceive + ", orderItems=" + orderItems + "]";
	}
	
}